PROJECTENGRAM

BGP AND INTERDOMAIN ROUTING

Tags: #◇Computer Science #◇NSCOM02 #◇Conceptual #◇BGP #◇Routing

◇Overview

Border Gateway Protocol (BGP) is the protocol that makes the internet work. It is an exterior gateway protocol (EGP) designed to exchange routing and reachability information among Autonomous Systems (AS) on the internet. Unlike interior protocols (like OSPF or RIP), BGP is a path-vector protocol that makes routing decisions based on paths, network policies, or rule-sets configured by a network administrator, prioritizing business policy over raw technical metrics like delay or hop count.

◇Key Definitions

  • Interdomain Routing: Routing between different Autonomous Systems.
  • BGP (Border Gateway Protocol): The standard path-vector interdomain routing protocol.
  • Autonomous System (AS): A collection of connected IP routing prefixes under the control of one or more network operators on behalf of a single administrative entity.
  • eBGP: Exterior BGP; sessions established between routers in different ASes.
  • iBGP: Interior BGP; sessions established between routers within the same AS.
  • Hot Potato Routing: Forwarding a packet to the nearest exit point out of the local AS to minimize internal transit costs.

◇Theoretical Framework / Core Concepts

Path-Vector Operations and BGP Messages

BGP peers establish sessions over TCP Port 179. BGP uses four main message types:

  1. OPEN: Establishes the connection and authenticates peers.
  2. UPDATE: Advertises new routing information (NLRI) or withdraws previously advertised routes.
  3. KEEPALIVE: Keeps the connection active (sent periodically).
  4. NOTIFICATION: Sent when an error is detected; immediately closes the BGP TCP connection.

Core BGP Attributes

BGP relies on attributes rather than simple metrics to choose the best path:

  • AS-PATH (Well-known mandatory): A sequence of AS numbers a route has traversed. Crucial for loop prevention: if a router sees its own AS in the AS-PATH, it drops the route.
  • LOCAL-PREF: Used inside an AS to choose the best outbound (exit) path. Higher is preferred.
  • MULTI-EXIT-DISC (MED): Used to suggest to an external AS the preferred inbound (entry) path into your AS. Lower is preferred.

◇Worked Examples / Protocol Walkthroughs / Calculations

BGP Loop Prevention Scenario

Assume AS 100 advertises a prefix 10.0.0.0/8 to AS 200. The AS-PATH is [100].
AS 200 forwards it to AS 300; AS-PATH becomes [200, 100].
If a misconfiguration sends this route back to AS 100, the edge router at AS 100 examines the AS-PATH. Finding 100 inside [200, 100], it drops the update, preventing a routing loop.

◇Summary & Key Takeaways

  • BGP is a Path-Vector Interdomain routing protocol that uses TCP 179.
  • Network policy and attributes (LOCAL-PREF, MED) dictate routing choices, not link speed.
  • The AS-PATH attribute fundamentally prevents routing loops at an inter-domain scale.
  • A NOTIFICATION message immediately tears down the peering session.

◇References & Navigation

CONFIRMATION // 理解度の確認

ACTIVE RECALL VERIFICATION

Select an answer to verify conceptual comprehension and reveal the technical rationale.

Q1

Which protocol is strictly classified as an Interdomain routing protocol?

Q2

What category of routing protocol does BGP fall under?

Q3

Which BGP message type is used to establish the initial connection and authenticate the peer?

Q4

What transport protocol and port does BGP use to establish peer connections?

Q5

Which of the following best defines an eBGP session?

Q6

What is the primary function of the BGP AS-PATH attribute?

Q7

Hot potato routing refers to a network's attempt to do what?

Q8

What action does a BGP router take immediately after sending a NOTIFICATION message?

Q9

How does a BGP router handle a received route if it sees its own AS number inside the AS-PATH attribute?

Q10

The LOCAL-PREF attribute is used to influence which of the following?

BGP and Interdomain Routing | PROJECT ENGRAM